package com.china.produce.listener;

import org.apache.rocketmq.spring.annotation.RocketMQMessageListener;
import org.apache.rocketmq.spring.core.RocketMQListener;
import org.springframework.stereotype.Component;

/**
 * @ClassName
 * @Author niujie
 * @Version
 * @Description
 * @CreateTime 2025/7/22
 */
@Component
@RocketMQMessageListener(topic = "test-topic", consumerGroup = "test-consumer-group")
public class RocketmqConsumerListener implements RocketMQListener<String> {
    @Override
    public void onMessage(String msg) {

        System.out.println("test-consumer-group 收到消息 ：" + msg);
    }
}
